﻿<%template _header%>
<%namespace YouHP.Model.Group%>
<%namespace YouHP.Utility%>
<!--header end-->

<!--主体-->

<div class="layout-cols2">
<div class="col1">

	<%if IsPost%>
	
		<%template _msgbox%>
		
	<%else%>
<div class="navgroup">

        <a href="{this.GetUrl("/User/Group/Index.aspx")}" <%if {PageName}=="index.aspx"%>
        class="current" <%/if%>><span>我的圈子</span></a>

        <a href="{this.GetUrl("/User/Group/Create.aspx")}"
        <%if {PageName}=="create.aspx"%>
        class="current"
        <%/if%>><span>创建圈子</span></a>
</div>
        
        
                <div class="box">
        			
	                <div class="content">
        <%if MyGroupList.Count==0%>
        <h1>您还没有自己的圈子！</h1>
        <%else%>
		               <div class="pannelbody">
			                <div class="mygrouplist">
        					

					                    <ul>
							                <li>&nbsp;</li>
							                <li>帖子数</li>
							                <li>回复数</li>
							                <li>浏览数</li>
							                <li>成员数</li>
                                            <li>角色</li>
						                </ul>

			                <form action="" method="post" ID="form1">
			                <input type="hidden" id="formid" name="formid" value="1" />
			                <input type="hidden" id="typeid" name="typeid" value="1" />
			                <input type="hidden" id="groupid" name="groupid" value="0" />
			                <input type="hidden" id="grouprole" name="grouprole" value="0" />
			                
        							
					                <table width="720px" cellpadding="0" cellspacing="0" border="0">
						                <tbody>
        						
						                <%csharp%> foreach(GroupInfo info in MyGroupList) { <%/csharp%>
					                  <tr class="messagetable" onmouseover="this.className='messagetableon'" onmouseout="this.className='messagetable'">
					                   <%csharp%>TempUrl = "/Group/Group.aspx?gid=" + info.Id;<%/csharp%>
					  	                <td width="80" align="center"><a href="{this.GetUrl(TempUrl)}"  target="_blank" class="user_img"><img src="{info.Logo}" width="48" height="48" id="usingavatarimg"  class ="photoimg" alt="头像"/></a><br /><span>{info.GroupName}</span></td>
        							   
					                    <td width="80">{info.TopicNum}</td>
					                    <td width="80">{info.ReplyNum}</td>
					                    <td width="80">{info.Hits}</td>
					                    <td width="80">{info.UserNum}</td>
					                    <td width="80">
                                        <%csharp%>if(info.Role==0){<%/csharp%>普通成员<%csharp%>}<%/csharp%>
                                        <%csharp%>if(info.Role==1){<%/csharp%>管理员<%csharp%>}<%/csharp%>
                                        <%csharp%>if(info.Role==2){<%/csharp%>圈主<%csharp%>}<%/csharp%>
					                    </td>
        							    
					                      <%csharp%>if(info.Role==1||info.Role==2){<%/csharp%>
					                    <td width="80">
					                    <a href="Setting.aspx?gid={info.Id}" class="selectall">管理</a>  
					                    </td>
					                     <%csharp%>}<%/csharp%>
					                     <%csharp%>if(info.Role==2){<%/csharp%>
					                    <td width="80"><a href="#" onclick="_$('typeid').value=1;_$('groupid').value={info.Id};_$('grouprole').value={info.Role};if(window.confirm('你是该圈子管理员，退出将删除此圈子，确定退出？')) _$('form1').submit();" class="selectall">退出</a>
					                    <%csharp%>} else {<%/csharp%>
					                    <td width="80"><a href="#" onclick="_$('typeid').value=1;_$('groupid').value={info.Id};_$('grouprole').value={info.Role};if(window.confirm('确定退出该圈子？')) _$('form1').submit();" class="selectall">退出</a>
					                    <%csharp%>}<%/csharp%>
					                    <td>&nbsp;</td>
					                </tr>
					                </tbody>
						                <%csharp%> } <%/csharp%>
					                </table>
        							 
        							
					                </form>
        						
                <div style="clear:both;"></div>
                    <div style="padding:10px;">
                        <div class="pages">
	                        {PagingString}
                        </div>
                    </div>
        									
                </div>
        						
        					
	                  </div>
        <%/if%>
	                </div>
                </div>
     <%/if%>           
</div>
	
  <div class="col2">
	    
  <%template _Menu%>
	
	</div>
</div>

<!--主体-->

<%template _footer%>
